﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

using MINERP.BLL.GroupMember;
using MINERP.MODEL.GroupMember;
using MINERP.MODEL.FoundationModel;

namespace MINERP.GroupMember
{
    public partial class FrmEPByPhotoSpec : Form
    {
        string _userName;
        GroupMemberBLL _bll = new GroupMemberBLL();
        public FrmEPByPhotoSpec(string userName)
        {
            InitializeComponent();
            _userName = userName;
        }

        private void FrmEPByPhotoSpec_Load(object sender, EventArgs e)
        {
            dtstartTime.DateTime = DateTime.Now.Date;
            dtEndTime.DateTime = DateTime.Now.Date.AddDays(1);
        }

        private void btnOk_Click(object sender, EventArgs e)
        {
            BindEP();
        }

        private void BindEP()
        {
            List<New_EmployeePerformanceBySpec_Info> eplist = _bll.GetEPByPhotoSpec(_userName, dtstartTime.DateTime, dtEndTime.DateTime);
            gcep.DataSource = eplist;
            gcep.RefreshDataSource();
        }
    }
}
